<div class="chit-chat-layer1">
    <div class="col-md-12 chit-chat-layer1-left">
        <div class="mail-toolbar clearfix">
            <div class="float-left">
                <button type="button" class="btn btn-primary" id="NewReward">设置新标准</button>
                <div class="clearfix"></div>
            </div>
            <div class="">
            </div>
        </div>
        <div class="grid_3 grid_4">
            <div class="page-header">
                <h3>奖惩标准</h3>
            </div>
            <div class="bs-example">
                <table class="table">
                    <tbody>
                    <tr>
                        <div class="btn-group m-r-sm mail-hidden-options" style="display: inline-block;">
                            <div class="btn-group">
                                <a class="btn btn-default dropdown-toggle rewardname" data-toggle="dropdown"
                                   aria-expanded="false" style="margin-bottom: 5px">等级标准<span class="caret"></span></a>
                                <ul class="dropdown-menu dropdown-menu-right" role="menu">
                                <#if pageViewReward?exists && pageViewReward.records?size gt 0>
                                    <#list pageViewReward.records as hrmReward>
                                        <li class="RewardContent">
                                            <input value="${hrmReward.id?default(0)}" class="hidden">
                                            <a class="getrewardId" style="cursor: pointer">${hrmReward.name?default("")}</a>
                                        </li>
                                    </#list>
                                <#else>
                                    <div style="text-align: center;padding-top: 10px">暂无相应数据</div>
                                </#if>
                                </ul>
                            </div>
                        </div>
                    </tr>
                    </tbody>
                    <tbody id="hrmRewardContaine">
                        <tr>
                            <td><h3>基础工资<a class="anchorjs-link">
                                <span class="anchorjs-icon"></span></a></h3></td>
                            <td class="type-info">${hrmReward.money?default(0)}元/月</td>
                        </tr>
                        <tr>
                            <td><h3>加班<a class="a2000元nchorjs-link"><span class="anchorjs-icon"></span></a></h3></td>
                            <td class="type-info">100元/次</td>
                        </tr>
                        <tr>
                            <td><h3>补贴<a class="anchorjs-link"><span class="anchorjs-icon"></span></a></h3></td>
                            <td class="type-info">${hrmReward.subsidy?default(0)}元/月</td>
                        </tr>
                        <tr>
                            <td><h3>全勤奖励<a class="anchorjs-link"><span class="anchorjs-icon"></span></a></h3></td>
                            <td class="type-info">500元/月</td>
                        </tr>
                        <tr>
                            <td><h3>缺勤扣除<a class="anchorjs-link"><span class="anchorjs-icon"></span></a></h3></td>
                            <td class="type-info">20元/天</td>
                        </tr>
                    </tbody>
                </table>
            </div>
        </div>
    </div>
</div>

<script>
    $(function () {
        $('.getrewardId').click(function () {
            var $this = $(this);
            var id = $this.prev().val();
            alert($this.prev().val());
            $.ajax({
                type: "POST",
                url: "/Pay/hrmRewardId.post",
                data: {id: id},
                success: function (data) {
                    $("#hrmRewardContaine").empty();
                    $("#hrmRewardContaine").append(data);
                },
                error:function (err) {
                    alert(err);
                }
            })
         })
        
        $('#NewReward').click(function () {
            
        })
    });
</script>